home *** CD-ROM | disk | FTP | other *** search
/ kermit.columbia.edu / kermit.columbia.edu.tar / kermit.columbia.edu / newsgroups / misc.20030409-20031118 / 000038_fdc@columbia.edu_Thu May 1 13:27:42 EDT 2003.msg < prev    next >
Text File  |  2003-11-18  |  4KB  |  98 lines

  1. Article: 14253 of comp.protocols.kermit.misc
  2. Path: newsmaster.cc.columbia.edu!news.columbia.edu!news-not-for-mail
  3. From: fdc@columbia.edu (Frank da Cruz)
  4. Newsgroups: comp.protocols.kermit.misc
  5. Subject: Re: Changed behavior of receive/transmit move-to
  6. Date: 1 May 2003 13:10:10 -0400
  7. Organization: Columbia University
  8. Lines: 81
  9. Message-ID: <b8rkdi$mo0$1@watsol.cc.columbia.edu>
  10. References: <b8rfll$kfv$1@cpimail.cpicorp.com>
  11. NNTP-Posting-Host: watsol.cc.columbia.edu
  12. X-Trace: newsmaster.cc.columbia.edu 1051809012 5710 128.59.39.139 (1 May 2003 17:10:12 GMT)
  13. X-Complaints-To: postmaster@columbia.edu
  14. NNTP-Posting-Date: 1 May 2003 17:10:12 GMT
  15. Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:14253
  16.  
  17. In article <b8rfll$kfv$1@cpimail.cpicorp.com>,
  18. Derek Chen-Becker  <dbecker@cpicorp.com> wrote:
  19. :      The behavior of the set receive move-to command seems to have 
  20. : changed between c-kermit 8.206 and 8.209. It used to resolve the full 
  21. : path of the move-to target upon each transfer, and now it appears to 
  22. : resolve it on login through IKSD. We have a directory structure like this:
  23. : ~/
  24. : ~/a
  25. : ~/a/incoming
  26. : ~/a/complete-rx
  27. : ~/a/outgoing
  28. : ~/a/complete-tx
  29. : ~/b
  30. : ~/b/incoming
  31. : ~/b/complete-rx
  32. : ~/b/outgoing
  33. : ~/b/complete-tx
  34. : The .kermrc for the account had lines like:
  35. : set receive move-to complete-rx
  36. : set send move-to complete-tx
  37. : Under 8.206 we could change to directory "a" or directory "b" and issue 
  38. : a send command like "send test.txt incoming/test.txt". The incomplete 
  39. : file during transfer would sit in the appropriate incoming directory and 
  40. : then would be moved to the approprate complete-rx directory on 
  41. : completion. Under 8.209 the completed files sit in the incoming 
  42. : directory unless we create a "complete-rx" directory in the home:
  43. : ~/complete-rx
  44. : and then they move there no matter which incoming directory they 
  45. : arrived in.
  46. :
  47. I would venture to say that the behavior you were relying on was not
  48. intentional.  Although my notes don't show it, I suspect that somebody else
  49. -- maybe even me -- was surprised when a relative directory name was not
  50. resolved in the context in which the command was given, especially since
  51. after changing contexts it might not be be valid.
  52.  
  53. : If this was for one or two sites we could work around it by creating 
  54. : different accounts for each one, but this is for 1200+ sites and one 
  55. : account makes it managable.
  56. :
  57. Well, when you put it that way I can see how deferred evaluation could be 
  58. useful too, in a use-at-your-own-risk sort of way.  But this turns out to
  59. be a rather tricky question, since immediate and deferred evaluation can
  60. be applied independently to the context (current directory for relative
  61. filespecs) and to any variables in the MOVE-TO or RENAME-TO string, e.g.:
  62.  
  63.   SET RECEIVE RENAME-TO \v(filename)_\v(ndate)_\v(ntime)_\v(userid)_\v(pid)
  64.  
  65. Deferring evaluation of the MOVE/RENAME-TO string until it is used means
  66. that an error might not be detected until hours into the operation, after
  67. everybody has gone home.
  68.  
  69. : If I could remotely set the send/receive move-to destinations, that 
  70. : might work, too.
  71. :
  72. That would be a change too.  But clearly changes are necessary, especially
  73. since in researching this I discovered that the SET RECEIVE RENAME-TO
  74. example (which is taken from the C-Kermit 7.0 update notes) is broken too.
  75.  
  76. My first reaction would be accept the MOVE-TO/RENAME-TO argument as-is
  77. at parse time, with no checking, and then evaluate it upon use.  This way,
  78. if you give an absolute pathname, it is constant; if you give a
  79. relative one, its resoluation varies with the context.  To extend same
  80. flexiblity to variables in the string, such as \v(time), we'd have to
  81. evaluate them at *parse* time.  If the user wanted to defer evaluation
  82. until use, s/he'd have to double the backslash.  A tad hard to explain,
  83. but it leaves the user with every combination of choices.  If I get a
  84. chance to work on the code again, I'll try this and see how it feels.
  85.  
  86. In the meantime, I'd recommend you fall back to whatever version of
  87. C-Kermit you were using before.
  88.  
  89. Thanks for the report.
  90.  
  91. - Frank
  92.